﻿<%@ Page Language="C#" AutoEventWireup="true" MasterPageFile="~/Components/Components.Master" CodeBehind="UpdateRegion.aspx.cs" Inherits="AjaxControlFramework.Docs.Components.UpdateRegion" %>
<%@ Register TagPrefix="docs" TagName="Example1" Src="~/Examples/UpdateRegion/Example1.ascx" %>

<asp:Content runat="server" ContentPlaceHolderID="HeadTitle">
    UpdateRegion - Components - Docs - AJAX Control Framework
</asp:Content>

<asp:Content runat="server" ContentPlaceHolderID="Title">
    <span class="underline">UpdateRegion</span> (AjaxControlFramework.UpdateRegion)
</asp:Content>

<asp:Content runat="server" ContentPlaceHolderID="Overview">
    <p>
        The <span class="code_element">UpdateRegion</span> is one of the out-of-the-box Ajaxified UI controls that is 
        packaged with the <span class="important">AJAX Control Framework</span>. It is a non-visual component that 
        allows developers to turn PostBack driven, hardly dynamic and slow sections of markup in quick, lean and delicious 
        sections. Simply wrap a portion of your markup with the start and end tags of an <span class="code_element">UpdateRegion</span> 
        control and *POOF* all PostBack events within that region will be intercepted and handled within an 
        AJAX call. That region's markup will automatically be replaced with updated markup returned by the AJAX call.
    </p>
</asp:Content>

<asp:Content runat="server" ContentPlaceHolderID="Remarks">
    <p>
        The <span class="code_element">UpdateRegion</span> control is the equivalent of the <span class="code_element">UpdatePanel</span> control included in <span class="important">ASP.NET AJAX</span>. I know what you're 
        thinking. "Oh great...ANOTHER <span class="code_element">UpdatePanel</span> knock off." It's true that this particular control has been done before, 
        and numerous times. But the <span class="important">AJAX Control Framework</span>'s <span class="code_element">UpdateRegion</span> is different though. There are a number of aspects 
        of how the <span class="code_element">UpdateRegion</span> operates in the context of the <span class="important">AJAX Control Framework</span> that make 
        it extraordinarily relevant.<br />
    </p>
    
    <strong>Here's what makes the <span class="important">AJAX Control Framework</span>'s <span class="code_element">UpdateRegion</span> better than all the others:</strong>
    
    <ul>
        <li>ViewState is tracked for the contents of the <span class="code_element">UpdateRegion</span> <span class="important">only</span>. This means that the overhead of ViewState processing is dramatically reduced to the bare essentials. (Unfortunately though, the ViewState of parent controls is not tracked during the <span class="code_element">UpdateRegion</span>'s AJAX calls, so referencing ViewState-bound parent controls within the <span class="code_element">UpdateRegion</span> is not supported. But, you should be avoiding such dependencies anyway.)</li>
        <li>The <span class="code_element">UpdateRegion</span> focuses on loading and re-rendering <span class="important">just</span> its contents, and avoids all of the parent Page's lifecycle events after Init. Only the <span class="code_element">UpdateRegion</span> has all of its Page Lifecycle events invoked. And <span class="important">still</span>, the <span class="code_element">UpdateRegion</span> operates exactly as it would if a normal PostBack were being performed.</li>
        <li>Because the <span class="code_element">UpdateRegion</span> is processed by the <span class="important">AJAX Control Framework</span>'s efficient communication strategy, only data relevant to the <span class="code_element">UpdateRegion</span>'s content is passed to and from the server (minus the encoded ViewState, or course).</li>
    </ul>
</asp:Content>
    
<asp:Content runat="server" ContentPlaceHolderID="Examples">
    <docs:Example1 runat="server" />
</asp:Content>